package com.atguigu.yygh.cmn.service;

import com.atguigu.yygh.model.cmn.Dict;
import com.baomidou.mybatisplus.extension.service.IService;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.List;

@Mapper
public interface DictService extends IService<Dict> {
    /**根数据id查询子数据列表**/
    List<Dict> findChildData(Long id);

    /**导出数据字典**/
    void exportData(HttpServletResponse response) throws IOException;

    /**导入数字典**/
    void importDictData(MultipartFile file);

    /**根据dictcode和value查询**/
    String getDictName(String dictCode, String value);

    /**根据数据id查询子数据列表**/
    List<Dict> findByDictCode(String dictCode);
}
